import random
s=[]
for i in range(10):
    s.append(random.randint(1,1000))


r1=[i for i in range(10) if s[i]%2==0]
print(r1)
r2=[s[i] for i in range(10) if s[i]%2==0]
print(r2)
s.reverse()
print(s)
print(s[0], s[len(s)-1])

